import java.io.BufferedReader;
import java.io.FileReader;
import java.io.FileWriter;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.io.Reader;
import java.io.Writer;
import java.util.StringTokenizer;

/**
 *
 * @author Alexander Fedulin.
 */
public class ProblemC
{
    static final String problem_input = "c.in";
    static final String problem_output = "c.out";
    private StringTokenizer st;
    private BufferedReader br;
    private PrintWriter out;
    private int ti, tr, te, td, n, m;
    private String s, t;
    private HashMap <Integer, Integer> dp;

    void load() throws IOException
    {
    	ti = nextInt();
    	td = nextInt();
    	tr = nextInt();
    	te = nextInt();
    	s = nextToken();
    	n = s.length();
    	t = nextToken();
    	m = t.length();
    }

    void solve()
    {
		
    }

    public void run()
    {
        try
        {
            boolean oj = System.getProperty("ONLINE_JUDGE") != null;
            Reader reader = oj ? new InputStreamReader(System.in) : new FileReader(problem_input);
            Writer writer = oj ? new OutputStreamWriter(System.out) : new FileWriter(problem_output);
            br = new BufferedReader(reader);
            out = new PrintWriter(writer);
            load();
            solve();
            out.close();
        }
        catch(Exception e)
        {
            e.printStackTrace();
            System.exit(42);
        }
    }

    private String nextToken() throws IOException
    {
        while (st == null || (!st.hasMoreTokens()))
        {
                st = new StringTokenizer(br.readLine());
        }
        return st.nextToken();
    }

    int nextInt() throws IOException
    {
        return Integer.parseInt(nextToken());
    }

    long nextLong() throws IOException
    {
        return Long.parseLong(nextToken());
    }

    void nextArray(int a[], int size) throws IOException
    {
        a = new int[size];
        for (int i = 0; i < size; i++)
                a[i] = nextInt();
    }

    void nextArray(double a[], int size) throws IOException
    {
        a = new double[size];
        for (int i = 0; i < size; i++)
            a[i] = nextDouble();
    }

    void nextArray(String a[], int size) throws IOException
    {
        a = new String[size];
        for (int i = 0; i < size; i++)
            a[i] = nextToken();
    }

    String readAll() throws IOException
    {
        String a = "";
		st = null;
		while (br.ready())
			a += br.read();
        return a;
    }

    double nextDouble() throws IOException
    {
		return Double.parseDouble(nextToken());
    }

    public static void main(String []args)
    {
		new ProblemC().run();
    }
}
